package com.easy.service.impl;

import com.easy.bean.MemberType;
import com.easy.dao.IMemberTypeDao;
import com.easy.service.IMemberTypeService;
import com.easy.utils.Page;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Collections;
import java.util.List;

@Service
public class MemberTypeImpl implements IMemberTypeService {

    @Autowired
    IMemberTypeDao dao;

    @Override
    public List<MemberType> getAllMemberType(MemberType memberType, Page page) {
        return dao.getAllMemberType(memberType,page);
    }

    @Override
    public int getMemberTypeCount(MemberType memberType) {
        return dao.getMemberTypeCount(memberType);
    }

    @Override
    public MemberType getMemberTypeByID(int id) {
        return dao.getMemberTypeByID(id);
    }

    @Override
    public int addMemberType(MemberType memberType) {
        return dao.addMemberType(memberType);
    }

    @Override
    public int delMemberType(int id) {
        return dao.delMemberType(id);
    }

    @Override
    public int editMemberType(MemberType memberType) {
        return dao.editMemberType(memberType);
    }
}
